import java.io.PrintWriter;
import java.util.HashMap;

class ComplexType extends Type {

	private String name_;

	public ComplexType(String string) {
		name_ = string;
	}

	@Override
	public void print(PrintWriter pw) {
		pw.println("Node name : ComplexType");
		pw.println("Type is : " + name_);
	}

	@Override
	public String translate(HashMap<String, PrintWriter> pws, String pare, SymbolTable rt,
			String parent) {
		String key = rt.getStack().get(1);
		PrintWriter pw = pws.get(key);

		// name_.translate(pw,null);
		return name_;
	}

	@Override
	public String getName() {
		return name_;
	}
}